package edu.uclmgmu.bacteriosec.aspects.bufferedreader;

import java.io.BufferedReader;

import edu.uclmgmu.bacteriosec.aspects.common.Store;

privileged aspect BufferedReader_CountCalls {

	String around(java.io.BufferedReader f) : target(f) && args() &&  call(* BufferedReader.readLine()) {
		int counter=Store.get(thisJoinPointStaticPart.getSignature());
		Store.updateNumberOfCalls(thisJoinPointStaticPart.getSignature(), counter++);
		Store.put(thisJoinPointStaticPart.getSignature(), counter);
		System.out.println(counter);
		return proceed(f);
	}
}
